package com.yx.backstage.controller;


import com.yx.backstage.manager.ManagerManager;
import com.yx.backstage.model.param.ManagerParam;
import com.yx.backstage.model.vo.ManagerVo;
import com.yx.backstage.config.global.CommonResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>
 * 管理员表 前端控制器
 * </p>
 *
 * @author YangXiong
 * @since 2023-03-25
 */
@Slf4j
@RestController
@RequestMapping("/manager")
@Api(tags = "管理员信息接口")
public class ManagerController {
    @Resource
    private ManagerManager managerManager;

    @PostMapping("/list")
    @ApiOperation("系统管理员列表")
    private CommonResult<List<ManagerVo>> pageList(@RequestBody ManagerParam param) {
        log.info("ManagerController pageList info ManagerParam={}", param);
        return managerManager.pageList(param);
    }

}

